package com.wuchao.spring.aop;

import com.wuchao.entity.User;
import lombok.extern.slf4j.Slf4j;

import java.util.Scanner;

/**
 * @Author wuchao66
 * @Date 2022/7/1 11:19
 * @Version 1.0
 */
@Slf4j
public class PointCut {//切入点
    public void show(User user){
        log.info("用户的名字是"+user.getName());
        System.out.println("请输入数字 3爆炸");
        int i = new Scanner(System.in).nextInt();
        if(i==3){
            throw new RuntimeException("bc");
        }else{
            System.out.println("输入数字:"+i);
        }

    }
}
